package com.ruoyi.talk.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.talk.mapper.GroupRecordChatMapper;
import com.ruoyi.talk.domain.GroupRecordChat;
import com.ruoyi.talk.service.IGroupRecordChatService;

/**
 * 群组聊天记录Service业务层处理
 * 
 * @author HaiWang
 * @date 2023-05-18
 */
@Service
public class GroupRecordChatServiceImpl implements IGroupRecordChatService 
{
    @Autowired
    private GroupRecordChatMapper groupRecordChatMapper;

    /**
     * 查询群组聊天记录
     * 
     * @param groupChatRecordId 群组聊天记录主键
     * @return 群组聊天记录
     */
    @Override
    public GroupRecordChat selectGroupRecordChatByGroupChatRecordId(Long groupChatRecordId)
    {
        return groupRecordChatMapper.selectGroupRecordChatByGroupChatRecordId(groupChatRecordId);
    }

    /**
     * 查询群组聊天记录列表
     * 
     * @param groupRecordChat 群组聊天记录
     * @return 群组聊天记录
     */
    @Override
    public List<GroupRecordChat> selectGroupRecordChatList(GroupRecordChat groupRecordChat)
    {
        return groupRecordChatMapper.selectGroupRecordChatList(groupRecordChat);
    }

    /**
     * 新增群组聊天记录
     * 
     * @param groupRecordChat 群组聊天记录
     * @return 结果
     */
    @Override
    public int insertGroupRecordChat(GroupRecordChat groupRecordChat)
    {
        return groupRecordChatMapper.insertGroupRecordChat(groupRecordChat);
    }

    /**
     * 修改群组聊天记录
     * 
     * @param groupRecordChat 群组聊天记录
     * @return 结果
     */
    @Override
    public int updateGroupRecordChat(GroupRecordChat groupRecordChat)
    {
        return groupRecordChatMapper.updateGroupRecordChat(groupRecordChat);
    }

    /**
     * 批量删除群组聊天记录
     * 
     * @param groupChatRecordIds 需要删除的群组聊天记录主键
     * @return 结果
     */
    @Override
    public int deleteGroupRecordChatByGroupChatRecordIds(Long[] groupChatRecordIds)
    {
        return groupRecordChatMapper.deleteGroupRecordChatByGroupChatRecordIds(groupChatRecordIds);
    }

    /**
     * 删除群组聊天记录信息
     * 
     * @param groupChatRecordId 群组聊天记录主键
     * @return 结果
     */
    @Override
    public int deleteGroupRecordChatByGroupChatRecordId(Long groupChatRecordId)
    {
        return groupRecordChatMapper.deleteGroupRecordChatByGroupChatRecordId(groupChatRecordId);
    }
}
